
_trg=createTrigger["EmptyDetector",getPos player]; 
_trg setTriggerArea[50,50,0,false];
_trg setTriggerActivation["CIV","PRESENT",true];

_civil = this;

_civMarker=createMarker ["civil", (getPos _civil)];
_civMarker setMarkerShape "ICON";
_civMarker setMarkerType "DOT";
_civMarker setMarkerColor "ColorBlack";

_flag=true;

while { true } do
{	

	if( (player distance _civil) >= 100 or ((_civil knowsAbout Player) <= 0.7) ) then {
		_civMarker setMarkerColor "ColorBlack";
	};

	waitUntil { ((player distance _civil) < 100) and ((_civil knowsAbout Player) > 0.7) };
	
	//if( (_civil knowsAbout Player) > 0.7) then {

		_civMarker setMarkerPos (getPos _civil);
		sleep 0.5;
	

	
	
		if ( _flag ) then
		{
			_civMarker setMarkerColor "ColorBlack";
		}else{
			
			_civMarker setMarkerColor "ColorRed";
		};

		_flag=!_flag;


	//};

	//_civil GlobalChat (format["KnowAbout : %1", (_civil knowsAbout Player) ]);

};// fin while gameEnd